package com.hdu.hdu.interceptor;


import com.hdu.hdu.context.StudentInfoCheckContext;

public class EmailCheckInterceptor implements Interceptor<StudentInfoCheckContext> {
    @Override
    public void handle(StudentInfoCheckContext context) {
        String email = context.getStudent().getEmail();
        if (email == null || email.isEmpty()) {
            context.getErrorMsg().put("EmailCheckInterceptor", "email is empty");
        }
    }
}
